home *** CD-ROM | disk | FTP | other *** search
/ Games of Daze / Infomagic - Games of Daze (Summer 1995) (Disc 1 of 2).iso / x2ftp / msdos / libs / mlib / include / mobject.h < prev    next >
Encoding:
C/C++ Source or Header  |  1994-02-26  |  1.2 KB  |  44 lines

  1.  
  2. #ifndef __MOBJECT_H
  3. #define __MOBJECT_H
  4.  
  5. #ifndef __OBJECT_H
  6. typedef unsigned int         classType;
  7. typedef unsigned int         hashValueType;
  8. #endif
  9.  
  10. #define MOBJECT_ID      100
  11. #define USER_NEW_AND_DELETE
  12.  
  13. /////////////////////////////////////////////////////////////////////////////
  14.  
  15. #ifdef __OBJECT_H
  16. class MObject : public Object {
  17. #else
  18. class MObject {
  19. #endif
  20. public:
  21.                  MObject (void);
  22. #ifdef USER_NEW_AND_DELETE
  23.     void *                   operator new (size_t s);
  24.     void                     operator delete (void *p);
  25. #endif
  26.     virtual classType        isA (void);
  27. #ifdef __OBJECT_H
  28.     virtual LPSTR            nameOf (void);
  29.     virtual hashValueType    hashValue (void);
  30.     virtual int              isEqual (const Object& o);
  31. #else
  32.     friend ostream&         operator<< (ostream& os, MObject& o);
  33. #endif
  34.     virtual void             printOn (ostream& os);
  35.                 ~MObject (void) {};
  36. };
  37.  
  38. //////////////////////////////////////////////////////////////////////////////
  39.  typedef                     void (* IterFuncType) (MObject * , void *);
  40.  typedef                     BOOL (* CondFuncType) (MObject * , void *);
  41. //////////////////////////////////////////////////////////////////////////////
  42.  
  43. #endif
  44.